#ifndef KMEANS_H
#define KMEANS_H
#include "structs.h"

class kmeans
{
    public:
        kmeans(int numberPoints, int numberClusters);
        kmeans(int numberPoints, coordinates *& data_points, int numberClusters);
        void execute(centroid *& c);
        void print();
        virtual ~kmeans();
    protected:
    private:
        int numK;
        int numPoints;
        centroid * centroids;
        coordinates * data;

        void createTestData(int rangeMax);
        void pickCentroids(bool *& picked);
        void initializeCluster(int *& labels);
        bool calculateCentroids(int labels[], bool *& picked,coordinates *& tempCentroids);
        bool updateCentroids(int labels[], coordinates tempCentroids[]);
};

#endif // KMEANS_H
